package com.ly;

import com.ly.controller.AccountController;
import com.ly.controller.BusinessController;
import com.ly.entity.BankAccount;
import com.ly.utils.IOUtil;
import com.ly.utils.Menu;

import java.util.List;

/**
 * Author: LiYao
 * CreateTime: 2025-03-11 19:33
 * Description:
 * Version: 1.0
 */
public class Main {
    public static void main(String[] args) {
        AccountController accountController = new AccountController();
        BusinessController businessController = new BusinessController();
        while (true) {
            Menu.showMainMenu();
            int choice = IOUtil.getIntInput("请选择操作：");
            switch (choice) {
                case 0:
                    BankAccount accountFlag = accountController.login();
                    if(accountFlag!= null){
                        businessController.start(accountFlag);
                    }
                    break;
                case 1:
                    break;
                default:
                    System.out.println("无效选项，请重新输入");
            }
        }
    }
}
